Optimal. Leaf size=26 \[ \frac{i a (c-i c \tan (e+f x))^n}{f n} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.082872, antiderivative size = 26, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 3, integrand size = 29, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.103, Rules used = {3522, 3487, 32} \[ \frac{i a (c-i c \tan (e+f x))^n}{f n} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 3522
Rule 3487
Rule 32
Rubi steps
\begin{align*} \int (a+i a \tan (e+f x)) (c-i c \tan (e+f x))^n \, dx &=(a c) \int \sec ^2(e+f x) (c-i c \tan (e+f x))^{-1+n} \, dx\\ &=\frac{(i a) \operatorname{Subst}\left (\int (c+x)^{-1+n} \, dx,x,-i c \tan (e+f x)\right )}{f}\\ &=\frac{i a (c-i c \tan (e+f x))^n}{f n}\\ \end{align*}
Mathematica [A] time = 0.730002, size = 51, normalized size = 1.96 \[ \frac{i a (c \sec (e+f x))^n \exp (n (-\log (c \sec (e+f x))+\log (c-i c \tan (e+f x))))}{f n} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.013, size = 25, normalized size = 1. \begin{align*}{\frac{ia \left ( c-ic\tan \left ( fx+e \right ) \right ) ^{n}}{fn}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A] time = 1.67797, size = 32, normalized size = 1.23 \begin{align*} \frac{i \, a c^{n}{\left (-i \, \tan \left (f x + e\right ) + 1\right )}^{n}}{f n} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 1.67238, size = 61, normalized size = 2.35 \begin{align*} \frac{i \, a \left (\frac{2 \, c}{e^{\left (2 i \, f x + 2 i \, e\right )} + 1}\right )^{n}}{f n} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 17.0957, size = 119, normalized size = 4.58 \begin{align*} \begin{cases} x \left (i a \tan{\left (e \right )} + a\right ) & \text{for}\: f = 0 \wedge n = 0 \\x \left (i a \tan{\left (e \right )} + a\right ) \left (- i c \tan{\left (e \right )} + c\right )^{n} & \text{for}\: f = 0 \\a x + \frac{i a \log{\left (\tan ^{2}{\left (e + f x \right )} + 1 \right )}}{2 f} & \text{for}\: n = 0 \\\frac{i a \left (- i c \tan{\left (e + f x \right )} + c\right )^{n} \tan{\left (e + f x \right )}}{f n \tan{\left (e + f x \right )} + i f n} - \frac{a \left (- i c \tan{\left (e + f x \right )} + c\right )^{n}}{f n \tan{\left (e + f x \right )} + i f n} & \text{otherwise} \end{cases} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.67333, size = 31, normalized size = 1.19 \begin{align*} \frac{i \,{\left (-i \, c \tan \left (f x + e\right ) + c\right )}^{n} a}{f n} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]